<template>
  <div
    class="jy-style-height copyright-box"
    :style="{
      'background-image': `url(${publicUrls + 'free/style3/researchbg.png' + '?imageView2/3/format/webp'})`,
    }"
  >
    <img
      class="footer-logo-box"
      :src="publicUrls + 'free/style3/researchbglogo.png' + '?imageView2/3/format/webp'"
      alt=""
    />
    <div class="copyright-heard">
      <i class="freeIcon" @click="blankHome">&#xe642;</i>
      <span>策展团队</span>
    </div>
    <div class="copyright-content" v-if="commonStore.teamInfo.text "> 
      <!-- <div class="copyrightInfo" v-html="commonStore.copyrightInfo"></div> -->
      <scrollBox
        color="rgba(50, 43, 37, 1)"
        :scrollSrc="publicUrls + 'free/style3/pen.png'"
        v-if="Scrollheights"
        :remarks="commonStore.teamInfo?.text" 
       
        :byid="231234"
        :height="getScrollWComputed"
      >
        <template #solidBorder>
          <div class="solidBorder-child"></div>
        </template>
      </scrollBox>
    </div>
    <div v-if="!commonStore.teamInfo.text" class="is-null">
      <span>暂无内容</span>
    </div>
  </div>
  <MenuNavigation />
</template>
 
<script lang="ts">
export default defineComponent({
  name: 'style1', 
});
</script>
  
<script setup lang="ts">
import MenuNavigation from '@/freeComponents/menuNavigation/index.vue';
import { publicUrls } from '@/utils/minxin';
import { commonDataStore, useProjectStore } from '@/store';
import { defineComponent, nextTick, ref, computed } from 'vue';
import { useRouter, useRoute } from 'vue-router';
import ScrollBox from '../scrollBox.vue';

const commonStore = commonDataStore();
const store = useProjectStore();
const router = useRouter();
const route = useRoute(); 
const content = ref(null);
const Scrollheights = ref();
commonStore.getTeamContentDescription();
const htmlText = ref();
let viewportHeight = window.innerHeight;
Scrollheights.value = viewportHeight * 0.65;
const getScrollWComputed = computed(() => {
  let rootNode = document.documentElement;

  // 获取计算后的样式
  let computedStyle = window.getComputedStyle(rootNode);

  // 读取字体大小（注意这里返回的可能是一个包含单位的字符串，如"16px"）
  let fontSize = computedStyle.fontSize;

  // 如果你需要一个数字值（不带单位）进行计算，你可能需要解析这个字符串
  // 例如，使用正则表达式或split()方法去除单位，并将结果转换为数字
  let fontSizeNumber = parseFloat(fontSize.replace(/[^0-9.-]/g, ''));
  let heights = (fontSizeNumber / 144) * 550;
  return heights;
});
const blankHome = () => {
  router.push({ name: route.meta.loopType ? 'exhibitionHome' : 'templateedit' });
};
const Text = () => {
  // if (commonStore.teamInfo?.text) {
  //   htmlText.value =
  //     commonStore.teamInfo?.text +
  //     (commonStore.teamInfo?.value ? `<p><br>特别鸣谢单位：${commonStore.teamInfo?.value}</p>` : '');
  // }
};
Text();
</script>

<style scoped lang="less">
.copyright-box {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  padding: 88px 0;
  background-size: 100% 100%;
  background-repeat: no-repeat;
}
.copyright-heard {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 48px;
  margin-bottom: 48px;
  padding: 0 123px;
  span {
    font-family: SourceHanSerifCN-Bold;
    font-size: 32px;
    line-height: 48px;
    text-align: center;
    color: #623333;
  }
  .freeIcon {
    cursor: pointer;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    left: 123px;
    font-size: 24px;
    line-height: 24px;
    color: #623333;
  }
}
.copyright-content {
  flex: 1;
  max-width: 100%;
  width: 100%; 
  height: 560px;
  padding: 0px 123px;
}
.copyrightInfo {
  width: 100%;
  height: 100%;
}

.solidBorder-child {
  width: 4px;
  height: 100%;
  background: #623333;
  border-radius: 1px;
  opacity: 0.2;
}
:deep(.templatestyle1-scroll-box-tumb) {
  display: flex;
  justify-content: center;
  img {
    width: 24px;
    height: 24px;
  }
}
.is-null {
  margin: 0 auto;
  margin-top: 200px;
  width: 100%;
  text-align: center;
  // left: 52%;
  span {
    font-size: 20px;
    line-height: 32px;
    color: #623333;
    opacity: 0.38;
  }
}
.footer-logo-box {
  position: absolute;
  bottom: 8px; 
  left: 50%;
  transform: translateX(-50%);
  width: 276px; 
  height: 24px;
}
:deep(.unit-exbi-remarks-info-remarks){
  p{
    font-weight: 400 !important; 
  }
  p:nth-child(1){
    text-indent: 0em;
  }
}
</style>